<a href='https://github.com/angular/angular.js/edit/v1.6.x/docs/content/error/$location/isrcharg.ngdoc?message=docs(error%2Fisrcharg)%3A%20describe%20your%20change...' class='improve-docs btn btn-primary'><i class="glyphicon glyphicon-edit">&nbsp;</i>Improve this Doc</a>


<h1>Error: $location:isrcharg
  <div><span class='hint'>Wrong $location.search() argument type</span></div>
</h1>

<div>
    <pre class="minerr-errmsg" error-display="The first argument of the `$location#search()` call must be a string or an object.">The first argument of the `$location#search()` call must be a string or an object.</pre>
</div>

<h2>Description</h2>
<div class="description">
  <p>To resolve this error, ensure that the first argument for the <code>$location.search</code> call is a <code>string</code> or an object.
You can use the stack trace associated with this error to identify the call site that caused this issue.</p>
<p>To learn more, please consult the <a href="api/ng/service/$location"><code>$location</code></a> api docs.</p>

</div>


